package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.CarPackageMapper;
import com.ruoyi.system.domain.CarPackage;
import com.ruoyi.system.service.ICarPackageService;

/**
 * 汽车套餐Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-05-10
 */
@Service
public class CarPackageServiceImpl implements ICarPackageService 
{
    @Autowired
    private CarPackageMapper carPackageMapper;

    /**
     * 查询汽车套餐
     * 
     * @param id 汽车套餐主键
     * @return 汽车套餐
     */
    @Override
    public CarPackage selectCarPackageById(Long id)
    {
        return carPackageMapper.selectCarPackageById(id);
    }

    /**
     * 查询汽车套餐列表
     * 
     * @param carPackage 汽车套餐
     * @return 汽车套餐
     */
    @Override
    public List<CarPackage> selectCarPackageList(CarPackage carPackage)
    {
        return carPackageMapper.selectCarPackageList(carPackage);
    }

    /**
     * 新增汽车套餐
     * 
     * @param carPackage 汽车套餐
     * @return 结果
     */
    @Override
    public int insertCarPackage(CarPackage carPackage)
    {
        return carPackageMapper.insertCarPackage(carPackage);
    }

    /**
     * 修改汽车套餐
     * 
     * @param carPackage 汽车套餐
     * @return 结果
     */
    @Override
    public int updateCarPackage(CarPackage carPackage)
    {
        return carPackageMapper.updateCarPackage(carPackage);
    }

    /**
     * 批量删除汽车套餐
     * 
     * @param ids 需要删除的汽车套餐主键
     * @return 结果
     */
    @Override
    public int deleteCarPackageByIds(Long[] ids)
    {
        return carPackageMapper.deleteCarPackageByIds(ids);
    }

    /**
     * 删除汽车套餐信息
     * 
     * @param id 汽车套餐主键
     * @return 结果
     */
    @Override
    public int deleteCarPackageById(Long id)
    {
        return carPackageMapper.deleteCarPackageById(id);
    }
}
